package org.game.gobang.client.support;

import javafx.scene.Scene;
import javafx.scene.control.Label;
import javafx.scene.layout.GridPane;
import org.game.component.AlertBox;
import org.game.gobang.client.constant.ClientConstant;

public class SuccessBox extends AlertBox {
    private String title;

    public SuccessBox(String title) {
        super(title);
        this.title = title;
        ClientConstant.canClick = true;
        display();
    }

    @Override
    protected Scene slot() {
        GridPane gridPane = new GridPane();

        gridPane.add(new Label("赢家"), 0, 0);
        gridPane.add(new Label(this.title), 1, 0);

        return new Scene(gridPane);
    }
}